<template>
	<access-warning-log v-if="props.query.col === 1 && props.query.index === 1" v-bind="{...props}" />
	<traffic-warning v-if="props.query.col === 1 && props.query.index === 2" v-bind="{...props}" />
	<auth-fail v-if="props.query.col === 3 && props.query.index === 1" v-bind="{...props}" />
	<auth-expiring-list v-if="props.query.col === 3 && props.query.index === 2" v-bind="{...props}" />
	<house-indicator v-else-if="props.query.col === 2" :alarm-type="props.query.alarmType" v-bind="{...props}" />
	<device-offline v-if="props.query.deviceType" v-bind="{...props}"></device-offline>
</template>

<script setup lang="ts">
	import TrafficWarning from './traffic-warning.vue'
	import AccessWarningLog from './access-warning-log.vue'
	import AuthExpiringList from './auth-expiring-list.vue'
	import HouseIndicator from './house-indicator.vue'
	import DeviceOffline from './device-offline.vue'
	import AuthFail from './auth-fail.vue'

	const props = withDefaults(
		defineProps<{
			query?: any
			source?: string
			searchContainer?: string | boolean
		}>(),
		{
			query: {},
			searchContainer: '#top_search'
		}
	)
</script>

<style scoped></style>
